package kisti.lod.sindice;

import kisti.lod.sindice.query.TermFilterQuery;

import com.sindice.SindiceException;
import com.sindice.result.SearchResults;

/**
 * Extension of the Sindice Class to allow Queries using the filter
 * functionality of Sindice API V3
 * @author Basti
 *
 */
public class MySindice extends com.sindice.Sindice {
	public SearchResults termSearch(String term, boolean sortByDate, int page, String filters[]) throws SindiceException {
        return new TermFilterQuery(term, sortByDate, filters).doQuery(page);
	}
	
	public SearchResults termSearch(String term, boolean sortByDate, String[] filters) throws SindiceException {
		return new TermFilterQuery(term, sortByDate, filters).doQuery();
	}
	
	public SearchResults termSearch(String term, String[] filters) throws SindiceException {
		return new TermFilterQuery(term, false, filters).doQuery();
	} 
	
	public SearchResults termSearch(String term, int page, String[] filters) throws SindiceException {
		return new TermFilterQuery(term, false, filters).doQuery(page);
	}
}
